import request from "@/utils/request";

/**
 * 我的账户列表(侧边)
 */
export const getWalletAccountList = (data) =>
  request({
    url: "/finance/wallet/wallet_list",
    method: "post",
    data,
  });

/**
 * 提现
 */
export const withdraw = (data) =>
  request({
    url: "/finance/wallet/withdrawal",
    method: "post",
    data,
  });

/**
 * 交易明细
 */
export const getTradeList = (data) =>
  request({
    url: "/finance/wallet/search_transaction",
    method: "post",
    data,
  });

/**
 * 设置默认账户
 */
export const setDefaultAccount = (data) =>
  request({
    url: "/finance/wallet/default_account",
    method: "post",
    data,
  });
/**
 * 获取提现账户列表
 */
export const getWithdrawAccountList = (data) =>
  request({
    url: "/finance/wallet/search_bank_card",
    method: "post",
    data,
  });

/**
 * 添加银行卡
 */
export const addBankCard = (data) =>
  request({
    url: "/finance/wallet/bind_bank_card",
    method: "post",
    data,
  });
/**
 * 确认添加银行卡
 */
export const confirmAddBankCard = (data) =>
  request({
    url: "/finance/wallet/confirm_bind_bank_account",
    method: "post",
    data,
  });
/**
 * 支持银行列表
 */
export const getSupportBankList = (data) =>
  request({
    url: "/finance/member/bank_list",
    method: "post",
    data,
  });

/**
 * 提现签约
 */
export const withdrawSign = (data) =>
  request({
    url: "/finance/wallet/sign_contract",
    method: "post",
    data,
  });


/**
 * 充值
 */
export const recharge = (data) =>
  request({
    url: "/finance/wallet/recharge",
    method: "post",
    data,
  });